package maps.com.wsfk.ssm.user;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.wsfk.ssm.entity.HandBook;
import com.wsfk.ssm.entity.Picture;
import com.wsfk.ssm.entity.Zip;

public interface HandBookMapper {

	public List<HandBook> queryAllBookByUser(@Param(value = "userId")String userId);
	
	public int updateHandBook(HandBook handBook);
	
	public int addPicture(Picture picture);
	
	public List<HandBook> queryPageBookByUser(@Param(value = "userId")String userId,
											  @Param(value="startIndex")String startIndex,
											  @Param(value="endIndex")String endIndex);
	
	public int queryPageBookCountByUser(@Param(value = "userId")String userId);
	
	public HandBook queryById(@Param(value="id")String id);
	
	public int updateHandBookById(HandBook handBook);
	
	public HandBook queryBookByIdAndPublishStatus(@Param(value="id")String id);
	
	public int updateVersionById(HandBook handBook);
	
	public int addZip(Zip zip);
	
	public Zip queryZipByFileDir(@Param(value="fileDir") String fileDir);

	public Zip queryZipByBookId(@Param(value="bookId")String bookId);
	
	public int updateZip(Zip zip);
	
	
}
